-
-
Notifications
You must be signed in to change notification settings - Fork 493
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[4522] Fix items order in inventory adjustment dropdown. #4541
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @amanbhargav - I haven't done a manual test, but it looks pretty obvious that that's the fix! Can you add an automated test that confirms the functionality (that's what we mean by "tests to confirm the functionality" in the criteria for completion, please?
@cielf Apologies for the delay in progress. I need to update the logic and write test cases, so I am working on both. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Passes manual testing. @dorner Do you want to comment on the technical aspects?
All good on my end too! |
@amanbhargav: Your PR |
Resolves #4522
Description
The items in the inventory adjustment dropdown were appearing in an unexpected order when adding a new storage location. This PR fixes the issue by ensuring that the items are sorted alphabetically in the controller before being passed to the view.
Solution:
Added
.alphabetized
scope to theinventory_items
in theStorageLocationsController
to ensure items are sorted alphabetically before being displayed.Code Change:
Type of change
How Has This Been Tested?
I have tested this change locally by: